<?php

   include("./header.php");
   include("./conndb.php");
   $user = $_POST["username"];
   $pass = $_POST["userpass"];
   if ($conn) {
      $sql = "insert into vip(username,userpass)  values('$user','$pass')";
      $res = mysqli_query($conn,$sql);
      if ($res) {
         echo "success";
      } else {
         echo "fail";
      }
      
   } else {
     echo "connect error";
   }
    //关闭数据库
    mysqli_close($conn);
?>